<?php

// Start of yaml v.1.2.0

/**
 * Scalar entity styles usable by yaml_parse() callback methods.
 * @link http://php.net/manual/en/yaml.constants.php
 */
define('YAML_ANY_SCALAR_STYLE', 0);
define('YAML_PLAIN_SCALAR_STYLE', 1);
define('YAML_SINGLE_QUOTED_SCALAR_STYLE', 2);
define('YAML_DOUBLE_QUOTED_SCALAR_STYLE', 3);
define('YAML_LITERAL_SCALAR_STYLE', 4);
define('YAML_FOLDED_SCALAR_STYLE', 5);

/**
*      &quot;tag:yaml.org,2002:null&quot;     
*/
define('YAML_NULL_TAG', 'tag:yaml.org,2002:null');
/**
*      &quot;tag:yaml.org,2002:bool&quot;     
*/
define('YAML_BOOL_TAG', 'tag:yaml.org,2002:bool');
/**
*      &quot;tag:yaml.org,2002:str&quot;     
*/
define('YAML_STR_TAG', 'tag:yaml.org,2002:str');
/**
*      &quot;tag:yaml.org,2002:int&quot;     
*/
define('YAML_INT_TAG', 'tag:yaml.org,2002:int');
/**
*      &quot;tag:yaml.org,2002:float&quot;     
*/
define('YAML_FLOAT_TAG', 'tag:yaml.org,2002:float');
/**
*      &quot;tag:yaml.org,2002:timestamp&quot;     
*/
define('YAML_TIMESTAMP_TAG', 'tag:yaml.org,2002:timestamp');
/**
*      &quot;tag:yaml.org,2002:seq&quot;     
*/
define('YAML_SEQ_TAG', 'tag:yaml.org,2002:seq');
/**
*      &quot;tag:yaml.org,2002:map&quot;     
*/
define('YAML_MAP_TAG', 'tag:yaml.org,2002:map');
/**
*      &quot;!php/object&quot;     
*/
define('YAML_PHP_TAG', '!php/object');

/**
*      让发射器(emitter)选择一个编码。     
*/
define('YAML_ANY_ENCODING', 0);
/**
*      以 UTF8 编码。     
*/
define('YAML_UTF8_ENCODING', 1);
/**
*      以 UTF16LE 编码。     
*/
define('YAML_UTF16LE_ENCODING', 2);
/**
*      以 UTF16BE 编码。     
*/
define('YAML_UTF16BE_ENCODING', 3);

/**
*      让发射器(emitter)选择一个换行符。     
*/
define('YAML_ANY_BREAK', 0);
/**
*      使用 <em>\r</em> 作为换行符(Mac 风格)。     
*/
define('YAML_CR_BREAK', 1);
/**
*      使用 <em>\n</em> 作为换行符(Unix 风格)。     
*/
define('YAML_LN_BREAK', 2);
/**
*      使用 <em>\r\n</em> 作为换行符(DOS 风格)。     
*/
define('YAML_CRLN_BREAK', 3);

/**
*<div id="function.yaml-emit-file" class="refentry">  <div class="refnamediv">   <h1 class="refname">yaml_emit_file</h1>   <p class="verinfo">(PECL yaml &gt;= 0.5.0)</p><p class="refpurpose"><span class="refname">yaml_emit_file</span> &mdash; <span class="dc-title">Send the YAML representation of a value to a file</span></p>   </div>   <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 description" id="refsect1-function.yaml-emit-file-description">   <h3 class="title">说明</h3>   <div class="methodsynopsis dc-description" style="border:1px gray;padding-left:5px;background:#232525">    <span class="type" style="color:#EAB766">bool</span> <span class="methodname" style="color:#CC7832"><strong>yaml_emit_file</strong></span>     ( <span class="methodparam"><span class="type" style="color:#EAB766">string</span> <span class="parameter" style="color:#2EACF9">$filename</span></span>    , <span class="methodparam"><span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.pseudo-types.php#language.types.mixed" class="type mixed" style="color:#EAB766">mixed</a></span> <span class="parameter" style="color:#2EACF9">$data</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">$encoding</span><span class="initializer"> = YAML_ANY_ENCODING</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">$linebreak</span><span class="initializer"> = YAML_ANY_BREAK</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">array</span> <span class="parameter" style="color:#2EACF9">$callbacks</span><span class="initializer"> = <strong><span>NULL</span></strong></span></span>   ]]] )</div>    <p class="para rdfs-comment">    Generate a YAML representation of the provided <span class="parameter" style="color:#2EACF9">data</span>    in the <span class="parameter" style="color:#2EACF9">filename</span>.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 parameters" id="refsect1-function.yaml-emit-file-parameters">   <h3 class="title">参数</h3>   <span>    <dl>            <dt> <span class="parameter" style="color:#2EACF9">filename</span></dt>       <dd>        <p class="para">        Path to the file.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">data</span></dt>       <dd>        <p class="para">        The <span class="parameter" style="color:#2EACF9">data</span> being encoded. Can be any type except        a <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.resource.php" class="type resource" style="color:#EAB766">resource</a></span>.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">encoding</span></dt>       <dd>        <p class="para">        Output character encoding chosen from        <strong><span>YAML_ANY_ENCODING</span></strong>,        <strong><span>YAML_UTF8_ENCODING</span></strong>,        <strong><span>YAML_UTF16LE_ENCODING</span></strong>,        <strong><span>YAML_UTF16BE_ENCODING</span></strong>.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">linebreak</span></dt>       <dd>        <p class="para">        Output linebreak style chosen from        <strong><span>YAML_ANY_BREAK</span></strong>,        <strong><span>YAML_CR_BREAK</span></strong>,        <strong><span>YAML_LN_BREAK</span></strong>,        <strong><span>YAML_CRLN_BREAK</span></strong>.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">callbacks</span></dt>       <dd>        <p class="para">        Content handlers for emitting YAML nodes. Associative <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.array.php" class="type array" style="color:#EAB766">array</a></span>        of classname =&gt; <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.callable.php" class="type callable" style="color:#EAB766">callable</a></span> mappings. See        <a href="http://php.net/manual/zh/yaml.callbacks.emit.php" class="link">emit callbacks</a> for more        details.       </p>      </dd>          </dl>    </span>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 returnvalues" id="refsect1-function.yaml-emit-file-returnvalues">   <h3 class="title">返回值</h3>   <p class="para">   Returns <strong><span>TRUE</span></strong> on success.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 changelog" id="refsect1-function.yaml-emit-file-changelog">   <h3 class="title">更新日志</h3>   <span>    <table class="doctable informaltable">           <thead>       <tr>        <th>版本</th>        <th>说明</th>       </tr>       </thead>       <tbody class="tbody">       <tr>        <td>1.1.0</td>        <td>         The <span class="parameter" style="color:#2EACF9">callbacks</span> parameter was added.        </td>       </tr>       </tbody>         </table>    </span>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 seealso" id="refsect1-function.yaml-emit-file-seealso">   <h3 class="title">参见</h3>   <span>    <ul class="simplelist">     <li class="member"><span class="function">{@link yaml_emit()} - Returns the YAML representation of a value</span></li>     <li class="member"><span class="function">{@link yaml_parse()} - Parse a YAML stream</span></li>    </ul>   </span>  </div>   <div class="up"><a href="http://php.net/manual/zh/ref.yaml.php">Yaml 函数</a></div></div>
 * @return bool Returns TRUE on success.*/
function yaml_emit_file($filename,$data,$encoding=YAML_ANY_ENCODING,$linebreak=YAML_ANY_BREAK,$callbacks=array()) {}

/**
*<div id="function.yaml-emit" class="refentry">  <div class="refnamediv">   <h1 class="refname">yaml_emit</h1>   <p class="verinfo">(PECL yaml &gt;= 0.5.0)</p><p class="refpurpose"><span class="refname">yaml_emit</span> &mdash; <span class="dc-title">Returns the YAML representation of a value</span></p>   </div>   <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 description" id="refsect1-function.yaml-emit-description">   <h3 class="title">说明</h3>   <div class="methodsynopsis dc-description" style="border:1px gray;padding-left:5px;background:#232525">    <span class="type" style="color:#EAB766">string</span> <span class="methodname" style="color:#CC7832"><strong>yaml_emit</strong></span>     ( <span class="methodparam"><span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.pseudo-types.php#language.types.mixed" class="type mixed" style="color:#EAB766">mixed</a></span> <span class="parameter" style="color:#2EACF9">$data</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">$encoding</span><span class="initializer"> = YAML_ANY_ENCODING</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">$linebreak</span><span class="initializer"> = YAML_ANY_BREAK</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">array</span> <span class="parameter" style="color:#2EACF9">$callbacks</span><span class="initializer"> = <strong><span>NULL</span></strong></span></span>   ]]] )</div>    <p class="para rdfs-comment">    Generate a YAML representation of the provided <span class="parameter" style="color:#2EACF9">data</span>.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 parameters" id="refsect1-function.yaml-emit-parameters">   <h3 class="title">参数</h3>   <span>    <dl>            <dt> <span class="parameter" style="color:#2EACF9">data</span></dt>       <dd>        <p class="para">        The <span class="parameter" style="color:#2EACF9">data</span> being encoded. Can be any type except        a <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.resource.php" class="type resource" style="color:#EAB766">resource</a></span>.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">encoding</span></dt>       <dd>        <p class="para">        Output character encoding chosen from        <strong><span>YAML_ANY_ENCODING</span></strong>,        <strong><span>YAML_UTF8_ENCODING</span></strong>,        <strong><span>YAML_UTF16LE_ENCODING</span></strong>,        <strong><span>YAML_UTF16BE_ENCODING</span></strong>.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">linebreak</span></dt>       <dd>        <p class="para">        Output linebreak style chosen from        <strong><span>YAML_ANY_BREAK</span></strong>,        <strong><span>YAML_CR_BREAK</span></strong>,        <strong><span>YAML_LN_BREAK</span></strong>,        <strong><span>YAML_CRLN_BREAK</span></strong>.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">callbacks</span></dt>       <dd>        <p class="para">        Content handlers for emitting YAML nodes. Associative <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.array.php" class="type array" style="color:#EAB766">array</a></span>        of classname =&gt; <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.callable.php" class="type callable" style="color:#EAB766">callable</a></span> mappings. See        <a href="http://php.net/manual/zh/yaml.callbacks.emit.php" class="link">emit callbacks</a> for more        details.       </p>      </dd>          </dl>    </span>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 returnvalues" id="refsect1-function.yaml-emit-returnvalues">   <h3 class="title">返回值</h3>   <p class="para">    Returns a YAML encoded <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.string.php" class="type string" style="color:#EAB766">string</a></span> on success.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 changelog" id="refsect1-function.yaml-emit-changelog">   <h3 class="title">更新日志</h3>   <span>    <table class="doctable informaltable">           <thead>       <tr>        <th>版本</th>        <th>说明</th>       </tr>       </thead>       <tbody class="tbody">       <tr>        <td>1.1.0</td>        <td>         The <span class="parameter" style="color:#2EACF9">callbacks</span> parameter was added.        </td>       </tr>       </tbody>         </table>    </span>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 examples" id="refsect1-function.yaml-emit-examples">   <h3 class="title">范例</h3>   <span>    <div class="example" id="example-4898">     <p><strong>Example #1 <span class="function"><strong style="color:#CC7832">yaml_emit()</strong></span> example</strong></p>     <div class="example-contents"> <div class="phpcode" style="border-color:gray;background:#232525"><span><span style="color: #000000"> <span style="color: #9876AA">&lt;?php<br />$addr&nbsp;</span><span style="color: #007700">=&nbsp;array(<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"given"&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"Chris"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"family"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"Dumars"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"address"</span><span style="color: #007700">=&gt;&nbsp;array(<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"lines"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"458&nbsp;Walkman&nbsp;Dr.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Suite&nbsp;#292"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"city"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"Royal&nbsp;Oak"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"state"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"MI"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"postal"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">48046</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;),<br />&nbsp;&nbsp;);<br /></span><span style="color: #9876AA">$invoice&nbsp;</span><span style="color: #007700">=&nbsp;array&nbsp;(<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"invoice"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">34843</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"date"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">980208000</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"bill-to"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">$addr</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"ship-to"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">$addr</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"product"</span><span style="color: #007700">=&gt;&nbsp;array(<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array(<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"sku"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"BL394D"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"quantity"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">4</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"description"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"Basketball"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"price"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">450</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;),<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array(<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"sku"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"BL4438H"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"quantity"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">1</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"description"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"Super&nbsp;Hoop"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"price"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">2392</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;),<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;),<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"tax"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">251.42</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"total"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #9876AA">4443.52</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"comments"</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">"Late&nbsp;afternoon&nbsp;is&nbsp;best.&nbsp;Backup&nbsp;contact&nbsp;is&nbsp;Nancy&nbsp;Billsmer&nbsp;@&nbsp;338-4338."</span><span style="color: #007700">,<br />&nbsp;&nbsp;);<br /></span><span style="color: #9876AA">var_dump</span><span style="color: #007700">(</span><span style="color: #9876AA">yaml_emit</span><span style="color: #007700">(</span><span style="color: #9876AA">$invoice</span><span style="color: #007700">));<br /></span><span style="color: #9876AA">?&gt;</span> </span> </span></div>     </div>      <div class="example-contents"><p>以上例程的输出类似于：</p></div>     <div class="example-contents screen" style="background:black;padding-left:5px;"> <div class="cdata"><span> string(628) &quot;--- invoice: 34843 date: 980208000 bill-to:   given: Chris   family: Dumars   address:     lines: |-       458 Walkman Dr.               Suite #292     city: Royal Oak     state: MI     postal: 48046 ship-to:   given: Chris   family: Dumars   address:     lines: |-       458 Walkman Dr.               Suite #292     city: Royal Oak     state: MI     postal: 48046 product: - sku: BL394D   quantity: 4   description: Basketball   price: 450 - sku: BL4438H   quantity: 1   description: Super Hoop   price: 2392 tax: 251.420000 total: 4443.520000 comments: Late afternoon is best. Backup contact is Nancy Billsmer @ 338-4338. ... &quot; </span></div>     </div>    </div>   </span>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 seealso" id="refsect1-function.yaml-emit-seealso">   <h3 class="title">参见</h3>   <span>    <ul class="simplelist">     <li class="member"><span class="function">{@link yaml_emit_file()} - Send the YAML representation of a value to a file</span></li>     <li class="member"><span class="function">{@link yaml_parse()} - Parse a YAML stream</span></li>    </ul>   </span>  </div>   <div class="up"><a href="http://php.net/manual/zh/ref.yaml.php">Yaml 函数</a></div></div>
 * @return string Returns a YAML encoded string on success.*/
function yaml_emit($data,$encoding,$linebreak,$callbacks=array()) {}

/**
*<div id="function.yaml-parse-file" class="refentry">  <div class="refnamediv">   <h1 class="refname">yaml_parse_file</h1>   <p class="verinfo">(PECL yaml &gt;= 0.4.0)</p><p class="refpurpose"><span class="refname">yaml_parse_file</span> &mdash; <span class="dc-title">Parse a YAML stream from a file</span></p>   </div>   <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 description" id="refsect1-function.yaml-parse-file-description">   <h3 class="title">说明</h3>   <div class="methodsynopsis dc-description" style="border:1px gray;padding-left:5px;background:#232525">    <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.pseudo-types.php#language.types.mixed" class="type mixed" style="color:#EAB766">mixed</a></span> <span class="methodname" style="color:#CC7832"><strong>yaml_parse_file</strong></span>     ( <span class="methodparam"><span class="type" style="color:#EAB766">string</span> <span class="parameter" style="color:#2EACF9">$filename</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">$pos</span><span class="initializer"> = 0</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">&$ndocs</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">array</span> <span class="parameter" style="color:#2EACF9">$callbacks</span><span class="initializer"> = <strong><span>NULL</span></strong></span></span>   ]]] )</div>    <p class="para rdfs-comment">    Convert all or part of a YAML document stream read from a file to a PHP variable.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 parameters" id="refsect1-function.yaml-parse-file-parameters">   <h3 class="title">参数</h3>   <span>    <dl>            <dt> <span class="parameter" style="color:#2EACF9">filename</span></dt>       <dd>        <p class="para">        Path to the file.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">pos</span></dt>       <dd>        <p class="para">        Document to extract from stream (<em>-1</em> for all        documents, <em>0</em> for first document, ...).       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">ndocs</span></dt>       <dd>        <p class="para">        If <span class="parameter" style="color:#2EACF9">ndocs</span> is provided, then it is filled with the        number of documents found in stream.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">callbacks</span></dt>       <dd>        <p class="para">        Content handlers for YAML nodes. Associative <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.array.php" class="type array" style="color:#EAB766">array</a></span> of YAML        tag =&gt; <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.callable.php" class="type callable" style="color:#EAB766">callable</a></span> mappings. See        <a href="http://php.net/manual/zh/yaml.callbacks.parse.php" class="link">parse callbacks</a> for more        details.       </p>      </dd>          </dl>    </span>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 returnvalues" id="refsect1-function.yaml-parse-file-returnvalues">   <h3 class="title">返回值</h3>   <p class="para">    Returns the value encoded in <span class="parameter" style="color:#2EACF9">input</span> in appropriate    PHP type 或者在失败时返回 <strong><span>FALSE</span></strong>. If <span class="parameter" style="color:#2EACF9">pos</span> is <em>-1</em> an    <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.array.php" class="type array" style="color:#EAB766">array</a></span> will be returned with one entry for each document found    in the stream.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 notes" id="refsect1-function.yaml-parse-file-notes">   <h3 class="title">注释</h3>   <div class="warning"><strong class="warning">Warning</strong>    <p class="para">     Processing untrusted user input with <span class="function"><strong style="color:#CC7832">yaml_parse_file()</strong></span>     is dangerous if the use of <span class="function">{@link unserialize()}</span> is enabled for     nodes using the <em>!php/object</em> tag. This behavior can be     disabled by using the <em>yaml.decode_php</em> ini setting.    </p>   </div>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 seealso" id="refsect1-function.yaml-parse-file-seealso">   <h3 class="title">参见</h3>   <span>    <ul class="simplelist">     <li class="member"><span class="function">{@link yaml_parse()} - Parse a YAML stream</span></li>     <li class="member"><span class="function">{@link yaml_parse_url()} - Parse a Yaml stream from a URL</span></li>     <li class="member"><span class="function">{@link yaml_emit()} - Returns the YAML representation of a value</span></li>    </ul>   </span>  </div>   <div class="up"><a href="http://php.net/manual/zh/ref.yaml.php">Yaml 函数</a></div></div>
 * @return mixed Returns the value encoded in input in appropriate PHP type or FALSE on failure. If pos is -1 an array will be returned with one entry for each document found in the stream.*/
function yaml_parse_file($filename,$pos=0,&$ndocs=null,$callbacks=array()) {}

/**
*<div id="function.yaml-parse-url" class="refentry">  <div class="refnamediv">   <h1 class="refname">yaml_parse_url</h1>   <p class="verinfo">(PECL yaml &gt;= 0.4.0)</p><p class="refpurpose"><span class="refname">yaml_parse_url</span> &mdash; <span class="dc-title">Parse a Yaml stream from a URL</span></p>   </div>   <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 description" id="refsect1-function.yaml-parse-url-description">   <h3 class="title">说明</h3>   <div class="methodsynopsis dc-description" style="border:1px gray;padding-left:5px;background:#232525">    <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.pseudo-types.php#language.types.mixed" class="type mixed" style="color:#EAB766">mixed</a></span> <span class="methodname" style="color:#CC7832"><strong>yaml_parse_url</strong></span>     ( <span class="methodparam"><span class="type" style="color:#EAB766">string</span> <span class="parameter" style="color:#2EACF9">$url</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">$pos</span><span class="initializer"> = 0</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">&$ndocs</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">array</span> <span class="parameter" style="color:#2EACF9">$callbacks</span><span class="initializer"> = <strong><span>NULL</span></strong></span></span>   ]]] )</div>    <p class="para rdfs-comment">    Convert all or part of a YAML document stream read from a URL to a PHP variable.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 parameters" id="refsect1-function.yaml-parse-url-parameters">   <h3 class="title">参数</h3>   <span>    <dl>            <dt> <span class="parameter" style="color:#2EACF9">url</span></dt>       <dd>        <p class="para">        <span class="parameter" style="color:#2EACF9">url</span> should be of the form &quot;scheme://...&quot;. PHP        will search for a protocol handler (also known as a wrapper) for that        scheme. If no wrappers for that protocol are registered, PHP will emit        a notice to help you track potential problems in your script and then        continue as though filename specifies a regular file.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">pos</span></dt>       <dd>        <p class="para">        Document to extract from stream (<em>-1</em> for all        documents, <em>0</em> for first document, ...).       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">ndocs</span></dt>       <dd>        <p class="para">        If <span class="parameter" style="color:#2EACF9">ndocs</span> is provided, then it is filled with the        number of documents found in stream.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">callbacks</span></dt>       <dd>        <p class="para">        Content handlers for YAML nodes. Associative <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.array.php" class="type array" style="color:#EAB766">array</a></span> of YAML        tag =&gt; <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.callable.php" class="type callable" style="color:#EAB766">callable</a></span> mappings. See        <a href="http://php.net/manual/zh/yaml.callbacks.parse.php" class="link">parse callbacks</a> for more       </p>      </dd>          </dl>    </span>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 returnvalues" id="refsect1-function.yaml-parse-url-returnvalues">   <h3 class="title">返回值</h3>   <p class="para">    Returns the value encoded in <span class="parameter" style="color:#2EACF9">input</span> in appropriate    PHP type 或者在失败时返回 <strong><span>FALSE</span></strong>. If <span class="parameter" style="color:#2EACF9">pos</span> is    <em>-1</em> an <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.array.php" class="type array" style="color:#EAB766">array</a></span> will be returned with one entry    for each document found in the stream.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 notes" id="refsect1-function.yaml-parse-url-notes">   <h3 class="title">注释</h3>   <div class="warning"><strong class="warning">Warning</strong>    <p class="para">     Processing untrusted user input with <span class="function"><strong style="color:#CC7832">yaml_parse_url()</strong></span>     is dangerous if the use of <span class="function">{@link unserialize()}</span> is enabled for     nodes using the <em>!php/object</em> tag. This behavior can be     disabled by using the <em>yaml.decode_php</em> ini setting.    </p>   </div>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 seealso" id="refsect1-function.yaml-parse-url-seealso">   <h3 class="title">参见</h3>   <span>    <ul class="simplelist">     <li class="member"><span class="function">{@link yaml_parse()} - Parse a YAML stream</span></li>     <li class="member"><span class="function">{@link yaml_parse_file()} - Parse a YAML stream from a file</span></li>     <li class="member"><span class="function">{@link yaml_emit()} - Returns the YAML representation of a value</span></li>    </ul>   </span>  </div>   <div class="up"><a href="http://php.net/manual/zh/ref.yaml.php">Yaml 函数</a></div></div>
 * @return mixed Returns the value encoded in input in appropriate PHP type or FALSE on failure. If pos is -1 an array will be returned with one entry for each document found in the stream.*/
function yaml_parse_url($url,$pos=0,&$ndocs=null,$callbacks=array()) {}

/**
*<div id="function.yaml-parse" class="refentry">  <div class="refnamediv">   <h1 class="refname">yaml_parse</h1>   <p class="verinfo">(PECL yaml &gt;= 0.4.0)</p><p class="refpurpose"><span class="refname">yaml_parse</span> &mdash; <span class="dc-title">Parse a YAML stream</span></p>   </div>   <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 description" id="refsect1-function.yaml-parse-description">   <h3 class="title">说明</h3>   <div class="methodsynopsis dc-description" style="border:1px gray;padding-left:5px;background:#232525">    <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.pseudo-types.php#language.types.mixed" class="type mixed" style="color:#EAB766">mixed</a></span> <span class="methodname" style="color:#CC7832"><strong>yaml_parse</strong></span>     ( <span class="methodparam"><span class="type" style="color:#EAB766">string</span> <span class="parameter" style="color:#2EACF9">$input</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">$pos</span><span class="initializer"> = 0</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">int</span> <span class="parameter" style="color:#2EACF9">&$ndocs</span></span>    [, <span class="methodparam"><span class="type" style="color:#EAB766">array</span> <span class="parameter" style="color:#2EACF9">$callbacks</span><span class="initializer"> = <strong><span>NULL</span></strong></span></span>   ]]] )</div>    <p class="para rdfs-comment">    Convert all or part of a YAML document stream to a PHP variable.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 parameters" id="refsect1-function.yaml-parse-parameters">   <h3 class="title">参数</h3>   <span>    <dl>            <dt> <span class="parameter" style="color:#2EACF9">input</span></dt>       <dd>        <p class="para">        The <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.string.php" class="type string" style="color:#EAB766">string</a></span> to parse as a YAML document stream.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">pos</span></dt>       <dd>        <p class="para">        Document to extract from stream (<em>-1</em> for all        documents, <em>0</em> for first document, ...).       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">ndocs</span></dt>       <dd>        <p class="para">        If <span class="parameter" style="color:#2EACF9">ndocs</span> is provided, then it is filled with the        number of documents found in stream.       </p>      </dd>                 <dt> <span class="parameter" style="color:#2EACF9">callbacks</span></dt>       <dd>        <p class="para">        Content handlers for YAML nodes. Associative <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.array.php" class="type array" style="color:#EAB766">array</a></span> of YAML        tag =&gt; <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.callable.php" class="type callable" style="color:#EAB766">callable</a></span> mappings. See        <a href="http://php.net/manual/zh/yaml.callbacks.parse.php" class="link">parse callbacks</a> for more        details.       </p>      </dd>          </dl>    </span>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 returnvalues" id="refsect1-function.yaml-parse-returnvalues">   <h3 class="title">返回值</h3>   <p class="para">    Returns the value encoded in <span class="parameter" style="color:#2EACF9">input</span> in appropriate    PHP type 或者在失败时返回 <strong><span>FALSE</span></strong>. If <span class="parameter" style="color:#2EACF9">pos</span> is <em>-1</em> an    <span class="type" style="color:#EAB766"><a href="http://php.net/manual/zh/language.types.array.php" class="type array" style="color:#EAB766">array</a></span> will be returned with one entry for each document found    in the stream.   </p>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 examples" id="refsect1-function.yaml-parse-examples">   <h3 class="title">范例</h3>   <span>    <div class="example" id="example-4899">     <p><strong>Example #1 <span class="function"><strong style="color:#CC7832">yaml_parse()</strong></span> example</strong></p>     <div class="example-contents"> <div class="phpcode" style="border-color:gray;background:#232525"><span><span style="color: #000000"> <span style="color: #9876AA">&lt;?php<br />$yaml&nbsp;</span><span style="color: #007700">=&nbsp;&lt;&lt;&lt;EOD<br /></span><span style="color: #DD0000">---<br />invoice:&nbsp;34843<br />date:&nbsp;"2001-01-23"<br />bill-to:&nbsp;&amp;id001<br />&nbsp;&nbsp;given:&nbsp;Chris<br />&nbsp;&nbsp;family:&nbsp;Dumars<br />&nbsp;&nbsp;address:<br />&nbsp;&nbsp;&nbsp;&nbsp;lines:&nbsp;|-<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;458&nbsp;Walkman&nbsp;Dr.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Suite&nbsp;#292<br />&nbsp;&nbsp;&nbsp;&nbsp;city:&nbsp;Royal&nbsp;Oak<br />&nbsp;&nbsp;&nbsp;&nbsp;state:&nbsp;MI<br />&nbsp;&nbsp;&nbsp;&nbsp;postal:&nbsp;48046<br />ship-to:&nbsp;*id001<br />product:<br />-&nbsp;sku:&nbsp;BL394D<br />&nbsp;&nbsp;quantity:&nbsp;4<br />&nbsp;&nbsp;description:&nbsp;Basketball<br />&nbsp;&nbsp;price:&nbsp;450<br />-&nbsp;sku:&nbsp;BL4438H<br />&nbsp;&nbsp;quantity:&nbsp;1<br />&nbsp;&nbsp;description:&nbsp;Super&nbsp;Hoop<br />&nbsp;&nbsp;price:&nbsp;2392<br />tax:&nbsp;251.420000<br />total:&nbsp;4443.520000<br />comments:&nbsp;Late&nbsp;afternoon&nbsp;is&nbsp;best.&nbsp;Backup&nbsp;contact&nbsp;is&nbsp;Nancy&nbsp;Billsmer&nbsp;@&nbsp;338-4338.<br />...<br /></span><span style="color: #007700">EOD;<br /><br /></span><span style="color: #9876AA">$parsed&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #9876AA">yaml_parse</span><span style="color: #007700">(</span><span style="color: #9876AA">$yaml</span><span style="color: #007700">);<br /></span><span style="color: #9876AA">var_dump</span><span style="color: #007700">(</span><span style="color: #9876AA">$parsed</span><span style="color: #007700">);<br /></span><span style="color: #9876AA">?&gt;</span> </span> </span></div>     </div>      <div class="example-contents"><p>以上例程的输出类似于：</p></div>     <div class="example-contents screen" style="background:black;padding-left:5px;"> <div class="cdata"><span> array(8) {   [&quot;invoice&quot;]=&gt;   int(34843)   [&quot;date&quot;]=&gt;   string(10) &quot;2001-01-23&quot;   [&quot;bill-to&quot;]=&gt;   &amp;array(3) {     [&quot;given&quot;]=&gt;     string(5) &quot;Chris&quot;     [&quot;family&quot;]=&gt;     string(6) &quot;Dumars&quot;     [&quot;address&quot;]=&gt;     array(4) {       [&quot;lines&quot;]=&gt;       string(34) &quot;458 Walkman Dr.         Suite #292&quot;       [&quot;city&quot;]=&gt;       string(9) &quot;Royal Oak&quot;       [&quot;state&quot;]=&gt;       string(2) &quot;MI&quot;       [&quot;postal&quot;]=&gt;       int(48046)     }   }   [&quot;ship-to&quot;]=&gt;   &amp;array(3) {     [&quot;given&quot;]=&gt;     string(5) &quot;Chris&quot;     [&quot;family&quot;]=&gt;     string(6) &quot;Dumars&quot;     [&quot;address&quot;]=&gt;     array(4) {       [&quot;lines&quot;]=&gt;       string(34) &quot;458 Walkman Dr.         Suite #292&quot;       [&quot;city&quot;]=&gt;       string(9) &quot;Royal Oak&quot;       [&quot;state&quot;]=&gt;       string(2) &quot;MI&quot;       [&quot;postal&quot;]=&gt;       int(48046)     }   }   [&quot;product&quot;]=&gt;   array(2) {     [0]=&gt;     array(4) {       [&quot;sku&quot;]=&gt;       string(6) &quot;BL394D&quot;       [&quot;quantity&quot;]=&gt;       int(4)       [&quot;description&quot;]=&gt;       string(10) &quot;Basketball&quot;       [&quot;price&quot;]=&gt;       int(450)     }     [1]=&gt;     array(4) {       [&quot;sku&quot;]=&gt;       string(7) &quot;BL4438H&quot;       [&quot;quantity&quot;]=&gt;       int(1)       [&quot;description&quot;]=&gt;       string(10) &quot;Super Hoop&quot;       [&quot;price&quot;]=&gt;       int(2392)     }   }   [&quot;tax&quot;]=&gt;   float(251.42)   [&quot;total&quot;]=&gt;   float(4443.52)   [&quot;comments&quot;]=&gt;   string(68) &quot;Late afternoon is best. Backup contact is Nancy Billsmer @ 338-4338.&quot; } </span></div>     </div>    </div>   </span>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 notes" id="refsect1-function.yaml-parse-notes">   <h3 class="title">注释</h3>   <div class="warning"><strong class="warning">Warning</strong>    <p class="para">     Processing untrusted user input with <span class="function"><strong style="color:#CC7832">yaml_parse()</strong></span>     is dangerous if the use of <span class="function">{@link unserialize()}</span> is enabled for     nodes using the <em>!php/object</em> tag. This behavior can be     disabled by using the <em>yaml.decode_php</em> ini setting.    </p>   </div>  </div>    <br></br><div style="BORDER-TOP: gray 1px dashed; OVERFLOW: hidden; HEIGHT: 1px"></div><div class="refsect1 seealso" id="refsect1-function.yaml-parse-seealso">   <h3 class="title">参见</h3>   <span>    <ul class="simplelist">     <li class="member"><span class="function">{@link yaml_parse_file()} - Parse a YAML stream from a file</span></li>     <li class="member"><span class="function">{@link yaml_parse_url()} - Parse a Yaml stream from a URL</span></li>     <li class="member"><span class="function">{@link yaml_emit()} - Returns the YAML representation of a value</span></li>    </ul>   </span>  </div>   <div class="up"><a href="http://php.net/manual/zh/ref.yaml.php">Yaml 函数</a></div></div>
 * @return mixed Returns the value encoded in input in appropriate PHP type or FALSE on failure. If pos is -1 an array will be returned with one entry for each document found in the stream.*/
function yaml_parse($input,$pos=0,&$ndocs=null,$callbacks=array()) {}
